package com.kaishengit.pojo;

import java.util.List;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.persistence.Transient;

import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;
import org.hibernate.annotations.GenericGenerator;

@Entity
@Table(name="t_note")
@Cache(usage=CacheConcurrencyStrategy.READ_WRITE)
public class Note {
	private String id;
	private String content;
	private String createtime;
	private String happentime;
	private String views;
	private User user;
	private String contactid;
	private String dealid;
	private String sendemail;
	private List<String> viewname;
	
	@Id
	@GenericGenerator(name="idGenerator" , strategy="uuid")
	@GeneratedValue(generator="idGenerator") 
	public String getId() {
		return id;
	}
	public void setId(String id) {
		this.id = id;
	}
	
	public String getSendemail() {
		return sendemail;
	}
	public void setSendemail(String sendemail) {
		this.sendemail = sendemail;
	}
	public String getContent() {
		return content;
	}
	public void setContent(String content) {
		this.content = content;
	}
	public String getCreatetime() {
		return createtime;
	}
	public void setCreatetime(String createtime) {
		this.createtime = createtime;
	}
	public String getHappentime() {
		return happentime;
	}
	public void setHappentime(String happentime) {
		this.happentime = happentime;
	}
	public String getViews() {
		return views;
	}
	public void setViews(String views) {
		this.views = views;
	}
	public String getContactid() {
		return contactid;
	}
	public void setContactid(String contactid) {
		this.contactid = contactid;
	}
	public String getDealid() {
		return dealid;
	}
	public void setDealid(String dealid) {
		this.dealid = dealid;
	}
	
	@ManyToOne
	@JoinColumn(name="userid")
	public User getUser() {
		return user;
	}
	public void setUser(User user) {
		this.user = user;
	}
	
	@Transient
	public List<String> getViewname() {
		return viewname;
	}
	public void setViewname(List<String> viewname) {
		this.viewname = viewname;
	}
	
	
	
	
	
}
